home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 5 / Skunkware 5.iso / src / X11 / lds / lds.h < prev    next >
C/C++ Source or Header  |  1995-05-03  |  5KB  |  109 lines

  1. /*************************************************************************
  2.  *                                                                       *
  3.  *  Copyright (c) 1992, 1993 Ronald Joe Record                           *
  4.  *                                                                       *
  5.  *  All rights reserved. No part of this program or publication may be   *
  6.  *  reproduced, transmitted, transcribed, stored in a retrieval system,  *
  7.  *  or translated into any language or computer language, in any form or *
  8.  *  by any means, electronic, mechanical, magnetic, optical, chemical,   *
  9.  *  biological, or otherwise, without the prior written permission of:   *
  10.  *                                                                       *
  11.  *      Ronald Joe Record (408) 458-3718                                 *
  12.  *      212 Owen St., Santa Cruz, California 95062 USA                   *
  13.  *                                                                       *
  14.  *************************************************************************/
  15.  
  16. Display *dpy;
  17. int xmax, ymax;
  18. int screen, fd;
  19. int histcol=1;
  20. int freq=1;
  21. int parity=0;
  22. int width=0; 
  23. int wide=0; 
  24. int height=0; 
  25. int high=0; 
  26. int quilt=1;
  27. int begin=1;
  28. int col=1;
  29. int draw=1;
  30. int minhist = MAXINT;
  31. int maxhist = 0;
  32. int logistic=1;            /* use logistic map */
  33. int tent=0;                /* use tent map */
  34. int circle=0;            /* use circle map if set */
  35. int Cflag=0;            /* Show connection strengths */
  36. int Eflag=0;            /* Evolve connection strengths */
  37. int sflag=0;            /* spatial histogram off */
  38. int hflag=0;            /* site histogram off */
  39. int oflag=0;            /* output file off */
  40. int vflag=0;            /* don't display text windows describing dynamics */
  41. int ranlam=0;            /* random lambda values off */
  42. int linlam=0;            /* linearly assigned lambda values off */
  43. int perlam=0;            /* periodically assigned lambda values off */
  44. int rancon=0;            /* random connection values off */
  45. int lincon=0;            /* linearly assigned connection values off */
  46. int percon=0;            /* periodically assigned connection values off */
  47. int eflag=0;            /* erase flag */
  48. int Pflag=0;            /* draw points flag */
  49. int mflag=0;             /* monochrome display (site value > 1/2 -> color) */
  50. int pflag=0;            /* generate phase 1st differences */
  51. int iflag=0;            /* initial conditions specified */
  52. int cflag=0;            /* draw curves */
  53. int xflag=0;            /* coupled map lattice mode */
  54. int xavg=4;                /* number of generations over which to average */
  55. int two_dim=0;            /* two dimensional lattice ? */
  56. int lamvalset=0;        /* non-linearity parameter specified */
  57. double RANGE=0.01;        /* range outside of which differences get graphed*/
  58. double erate=0.01;        /* rate at which connections evolve */
  59. double ORANGE=0.99;        /* 1-RANGE */
  60. double lamval=3.8;        /* default lambda value */
  61. double EC=0.8;            /* default center cell weight */
  62. double ER=0.05;        /* default right cell weight */
  63. double EL=0.05;        /* default left cell weight */
  64. double EU=0.05;        /* default upper cell weight */
  65. double ED=0.05;        /* default lower cell weight */
  66. double omega;            /* frequency in circle map or height in tent map */
  67. double incline, decline;    /* slope up and down (if tent) */
  68. char *valinit, *laminit;    /* initial values of array and lambdas */
  69. double **ctrconn;            /* initial values of center connection strength */
  70. double **rgtconn;             /* initial values of right connection strength */
  71. double **lftconn;             /* initial values of left connection strength */
  72. double **uprconn;             /* initial values of upper connection strength */
  73. double **lwrconn;             /* initial values of lower connection strength */
  74. int periodic=1;                /* periodic boundary conditions */
  75. int boundflag=0;            /* alternate boundary conditions specified */
  76. int A=1;                    /* frequency of sin wave of initial lambdas */
  77. int G=1;                    /* frequency of sin wave of initial connections */
  78. double **currentgen, **nextgen;    /* the current and next generation */
  79. double **avg;                /* array of averages to be used as parameters */
  80. double **lambda;                /* array of non-linearity parameters */
  81. double *diff;                /* array of 1st differences */
  82. double boundary=0.0;        /* default fixed boundary condition */
  83. int *histogram;                /* array of site histogram values */
  84. int **histarray;            /* array of spatial histogram values */
  85. char *outname = "lds.out";
  86.  
  87. unsigned long foreground, background, numgen;
  88.  
  89. Window canvas, hiswin, spahis;
  90.  
  91. typedef struct {
  92.     int x, y;
  93. } xy_t;
  94.  
  95. points_t Points, Hpoints;
  96.  
  97. GC Data_GC[MAXCOLOR];
  98.  
  99. int    mincolor, numcolors, displayplanes;
  100. Pixmap  pixmap, spamap;
  101. Colormap cmap, spcmap, hicmap;
  102. XColor    Colors[MAXCOLOR];
  103. int    numwheels=MAXWHEELS;
  104. int     rgb_max=65000, stripe_interval=7;
  105. int    savefile=0;
  106. int    run=1, xpoint=0, ypoint=0;
  107. extern double drand48(), sin(), fabs(), floor(), fmod();
  108. extern void srand48();
  109.